/**
 * Copyright (c) 2013-Now http://dreamcode123321.com All rights reserved.
 */
package com.jeesite.modules.ab.entity;

import javax.validation.constraints.NotBlank;
import org.hibernate.validator.constraints.Length;
import javax.validation.constraints.NotNull;
import java.util.Date;
import com.jeesite.common.mybatis.annotation.JoinTable;
import com.jeesite.common.mybatis.annotation.JoinTable.Type;
import com.fasterxml.jackson.annotation.JsonFormat;

import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;

/**
 * 室温数据表Entity
 * @author d＇c
 * @version 2020-07-12
 */
@Table(name="ab_data", alias="a", columns={
		@Column(name="data_code", attrName="dataCode", label="data_code", isPK=true),
		@Column(name="name", attrName="name", label="用户名", isQuery=false),
		@Column(name="company_code", attrName="companyCode", label="公司编码", isQuery=false),
		@Column(name="company_name", attrName="companyName", label="供热公司部门", queryType=QueryType.LIKE),
		@Column(name="area_code", attrName="areaCode", label="区域编码", isQuery=false),
		@Column(name="area_name", attrName="areaName", label="行政区域"),
		@Column(name="floor_code", attrName="floorCode", label="floor_code", isQuery=false),
		@Column(name="floor_name", attrName="floorName", label="小区楼宇", queryType=QueryType.LIKE),
		@Column(name="house_code", attrName="houseCode", label="楼宇编码", isQuery=false),
		@Column(name="equip_no", attrName="equipNo", label="测温id", isQuery=false),
		@Column(name="in_value", attrName="inValue", label="当前温度", isQuery=false),
		@Column(name="out_value", attrName="outValue", label="室外温度", isQuery=false),
		@Column(name="create_time", attrName="createTime", label="上传时间", isQuery=false),
	}, orderBy="a.data_code DESC"
)
public class AbData extends DataEntity<AbData> {
	
	private static final long serialVersionUID = 1L;
	private String dataCode;		// data_code
	private String name;		// 用户名
	private String companyCode;		// 公司编码
	private String companyName;		// 供热公司部门
	private String areaCode;		// 区域编码
	private String areaName;		// 行政区域
	private String floorCode;		// floor_code
	private String floorName;		// 小区楼宇
	private String houseCode;		// 楼宇编码
	private String equipNo;		// 测温id
	private Double inValue;		// 当前温度
	private Double outValue;		// 室外温度
	private Date createTime;		// 上传时间
	private Date beginTime;
	private Date endTime;

	public Date getBeginTime() {
		return beginTime;
	}

	public void setBeginTime(Date beginTime) {
		this.beginTime = beginTime;
	}

	public Date getEndTime() {
		return endTime;
	}

	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}

	public AbData() {
		this(null);
	}

	public AbData(String id){
		super(id);
	}

	public String getDataCode() {
		return dataCode;
	}

	public void setDataCode(String dataCode) {
		this.dataCode = dataCode;
	}

	@NotBlank(message="用户名不能为空")
	@Length(min=0, max=45, message="用户名长度不能超过 45 个字符")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	@NotBlank(message="公司编码不能为空")
	@Length(min=0, max=64, message="公司编码长度不能超过 64 个字符")
	public String getCompanyCode() {
		return companyCode;
	}

	public void setCompanyCode(String companyCode) {
		this.companyCode = companyCode;
	}
	
	@Length(min=0, max=200, message="供热公司部门长度不能超过 200 个字符")
	public String getCompanyName() {
		return companyName;
	}

	public void setCompanyName(String companyName) {
		this.companyName = companyName;
	}
	
	@NotBlank(message="区域编码不能为空")
	@Length(min=0, max=64, message="区域编码长度不能超过 64 个字符")
	public String getAreaCode() {
		return areaCode;
	}

	public void setAreaCode(String areaCode) {
		this.areaCode = areaCode;
	}
	
	@Length(min=0, max=200, message="行政区域长度不能超过 200 个字符")
	public String getAreaName() {
		return areaName;
	}

	public void setAreaName(String areaName) {
		this.areaName = areaName;
	}
	
	@Length(min=0, max=64, message="floor_code长度不能超过 64 个字符")
	public String getFloorCode() {
		return floorCode;
	}

	public void setFloorCode(String floorCode) {
		this.floorCode = floorCode;
	}
	
	@Length(min=0, max=200, message="小区楼宇长度不能超过 200 个字符")
	public String getFloorName() {
		return floorName;
	}

	public void setFloorName(String floorName) {
		this.floorName = floorName;
	}
	
	@NotBlank(message="楼宇编码不能为空")
	@Length(min=0, max=64, message="楼宇编码长度不能超过 64 个字符")
	public String getHouseCode() {
		return houseCode;
	}

	public void setHouseCode(String houseCode) {
		this.houseCode = houseCode;
	}
	
	@NotBlank(message="测温id不能为空")
	@Length(min=0, max=45, message="测温id长度不能超过 45 个字符")
	public String getEquipNo() {
		return equipNo;
	}

	public void setEquipNo(String equipNo) {
		this.equipNo = equipNo;
	}
	
	@NotNull(message="当前温度不能为空")
	public Double getInValue() {
		return inValue;
	}

	public void setInValue(Double inValue) {
		this.inValue = inValue;
	}
	
	@NotNull(message="室外温度不能为空")
	public Double getOutValue() {
		return outValue;
	}

	public void setOutValue(Double outValue) {
		this.outValue = outValue;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@NotNull(message="上传时间不能为空")
	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}


	
}